package com.endoc.designpattern.docorator;

import com.endoc.designpattern.entity.Bag;

/**
 * 加固装饰类,对原先的功能进行了增强
 */
public class ReinforceBagDecorator extends BagDecorator {
    public ReinforceBagDecorator(Bag bag) {
        super(bag);
    }

    @Override
    public void pack() {
        super.pack();
        reinforce();
    }

    private void reinforce() {
        System.out.println("对包装进行加固操作");
    }
}
